//
// Source code recreated from a .class file by IntelliJ IDEA
// (powered by Fernflower decompiler)
//

package com.baidu.trace.c;

import android.text.TextUtils;

public final class d {
    public static short a(byte[] var0, int var1) {
        return var0 != null && 2 <= var0.length?(short)(var0[0] << 8 | var0[1] & 255):0;
    }

    public static byte[] a(String var0) {
        return var0 == null?new byte[0]:var0.getBytes();
    }

    public static byte[] b(String var0) {
        byte[] var1 = new byte[6];
        if(TextUtils.isEmpty(var0)) {
            return var1;
        } else {
            try {
                String[] var5 = var0.split(":");
                int var2 = 6 <= var5.length?6:var5.length;

                for(int var3 = 0; var3 < var2; ++var3) {
                    var1[var3] = (byte)Integer.parseInt(var5[var3], 16);
                }
            } catch (Exception var4) {
                ;
            }

            return var1;
        }
    }

    static {
        "0123456789abcdef".getBytes();
    }
}
